package com.atguigu.gmall.activity.client;

import com.atguigu.gmall.common.result.Result;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

/**
 * 秒杀远程调用接口
 */
@FeignClient(name = "service-activity")
public interface SeckillGoodsFeignClient {

    //回显秒杀频道首页 所有秒杀的商品
    @GetMapping("/api/activity/seckill/findAll")
    public Result findAll();

    //根据SkuId查询一个秒杀商品
    @GetMapping("/api/activity/seckill/getSeckillGoods/{skuId}")
    public Result getSeckillGoods(@PathVariable(name = "skuId") Long skuId);

    //查询秒杀商品 准备订单详情集合
    @GetMapping("/api/activity/seckill/getOrderDetail/{userId}")
    public Result getOrderDetail(@PathVariable(name = "userId") String userId);
}
